<?php


/**
 * Radcodes - SocialEngine Module
 *
 * @category   Application_Extensions
 * @package    Gmap
 * @copyright  Copyright (c) 2009-2010 Radcodes LLC (http://www.radcodes.com)
 * @license    http://www.radcodes.com/license/
 * @version    $Id$
 * @author     Vincent Van <vincent@radcodes.com>
 */
 
 
?>
<?php if ($this->paginator->getTotalItemCount()): ?>
  <ul class="gmaps_most_liked">
    <?php foreach( $this->paginator as $item ): ?>
      <li>
        <?php if ($this->show_photo): ?>
          <div class="gmap_photo">
            <?php echo $this->htmlLink($item->getHref(), $this->itemPhoto($item, 'thumb.icon')) ?>
          </div>   
        <?php endif; ?> 
        <div class="gmap_info">   
          <div class="gmap_title">
            <?php echo $this->htmlLink($item->getHref(), $this->radcodes()->text()->truncate($item->getTitle(), $this->titlelength)); ?>
          </div> 
          <?php if ($this->show_details): ?>
            <div class="gmap_details">
              <?php if (!$this->show_photo): ?>
                <?php echo $this->timestamp($item->creation_date) ?> - 
              <?php endif; ?>
							<?php // echo $this->translate(array("%s view", "%s views", $item->view_count), $this->locale()->toNumber($item->view_count)); ?>
							<?php // echo $this->translate(array("%s comment", "%s comments", $item->comment_count), $this->locale()->toNumber($item->comment_count)); ?>
              <?php echo $this->translate(array('%1$s like', '%1$s likes', $item->like_count), $this->locale()->toNumber($item->like_count)); ?>
            </div>
          <?php endif; ?> 
        </div>       
      </li>
    <?php endforeach; ?>
  </ul>
<?php endif; ?>